package com.atlin.project.service;


import com.atlin.project.model.domain.cds.ClientCode;
import com.atlin.project.model.dto.clientCode.ClientCodeQueryRequest;
import com.atlin.project.model.vo.cds.CdsSyncCheckVo;
import com.atlin.project.model.vo.cds.ClientCodeVO;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * @author atlin
 * @description clientCode
 * @createDate date
 */
public interface ClientCodeService extends IService<ClientCode> {

    void valid(ClientCode clientCode, boolean add);

    /**
     * 获取封装
     *
     * @param clientCode
     * @param request
     * @return
     */
    ClientCodeVO getClientCodeVO(ClientCode clientCode, HttpServletRequest request);


    /**
     * 获取查询条件
     *
     * @param questionQueryRequest
     * @return
     */
    QueryWrapper<ClientCode> getQueryWrapper(ClientCodeQueryRequest questionQueryRequest);

    /**
     * 分页获取封装
     *
     * @param questionPage
     * @param request
     * @return
     */
    Page<ClientCodeVO> getClientCodeVOPage(Page<ClientCode> questionPage, HttpServletRequest request);

    /**
     * 客户端文件同步校验
     *
     * @param clientCode 客户端标识码
     * @return CdsSyncCheckVo
     */
    List<CdsSyncCheckVo> syncCheck(String clientCode);
}
